common/sysctl: Don't leak status in SYSCTL_page_offline_op
authorAndrew Cooper <andrew.cooper3@citrix.com>
Mon, 20 Jan 2014 08:48:11 +0000 (09:48 +0100)
committerJan Beulich <jbeulich@suse.com>
Mon, 20 Jan 2014 08:48:11 +0000 (09:48 +0100)
commitefd8ff0a04740a698b2b8b2b9adccd639e0fa6c9
tree03d2e203571eded7ed6e2fea39ad90aa24c2f4b9
parent58f5bcaf05621810f06bf5b3592e2ae87475053d
common/sysctl: Don't leak status in SYSCTL_page_offline_op

In addition, 'copyback' should be cleared even in the error case.

Also fix the indentation of the arguments to copy_to_guest() to help clarify
that the 'ret = -EFAULT' is not part of the condition.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Keir Fraser <keir@xen.org>
xen/common/sysctl.c